package com.libre.config;

import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.config.annotation.ResourceHandlerRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;

/**
* @description   添加自定义拦截器
* @author        庞留杰
* @date          2020/7/16 19:18
* @version       V1.0
**/
@Configuration
public class WebConfig implements WebMvcConfigurer {

    //访问静态资源
    @Override
    public void addResourceHandlers(ResourceHandlerRegistry registry) {
        //其中OTA表示访问的前缀。"file:D:/OTA/"是文件真实的存储路径
        //registry.addResourceHandler("/"+visitPrefix+"/**").addResourceLocations("file:"+filePath);
        //flowable静态资源
        registry.addResourceHandler("/modeler/**").addResourceLocations("classpath:/modeler/");
    }
}